#ifndef GAMEOBJECT_H
#define GAMEOBJECT_H

#include <QObject>

class AbstractObject : public QObject
{
    Q_OBJECT
public:
    explicit AbstractObject(QObject* parent = 0);

    QString id() const;
    QPointer<AbstractObject> parentObject() const;

    int guid() const { return m_guid; }
private:
    QString m_ID;
    QPointer<AbstractObject> m_parentObject;
    int m_guid;
    static int m_guids;
signals:
    void parentObjectChanged(QPointer<AbstractObject> newParent);
    void idChanged(const QString& newID);
public slots:
    void setID(const QString& id);
    void setParentObject(QPointer<AbstractObject> object);
};

#endif // GAMEOBJECT_H
